/*
 * Util.c
 *
 *  Created on: Dec 23, 2010
 *      Author: cesar
 */

#include "util.h"

/// <summary>
/// Imprime a string caso a flag de debug seja ativada
/// </summary>
/// <param name="format">Ponteiro da string.</param>
int DebugPrint(char* format, ...){
	int n = 0;
	va_list ap;

	if(DEBUGFLAG){
		printf("Debug: ");
		va_start(ap, format);
		n = vprintf(format, ap);
		va_end(ap);
		printf("\n");
	}

	return n;
}

